Some storage modules, such as memory cards or solid state drives, have a controller that includes both hardware function blocks and a processor that can execute firmware. When the controller receives an incoming command, the controller parses and classifies the command and determines if the op-code of the command (e.g., op-code 0x90) is known to the controller. If it is, the controller looks up the command attributes associated with the op-code and configures the hardware function blocks with those command attributes. The hardware function blocks then process the command (e.g., by reading or writing data or by managing data specified in the command) according to the associated command attributes. While the same processing can be done in firmware, the hardware function blocks can perform the processing faster. If the op-code of the command is unknown to the controller, the controller does not have the command attributes with which to configure the hardware function blocks, and the command is processed by the firmware.
The association between op-codes and command attributes is defined during the design phase of the controller and is hardwired into the controller during manufacturing. So, during the application-specific integrated circuit (ASIC) chip design of the controller, respective command attributes are defined for each command that may be issued by a host (e.g., as defined in a standard), and the association between op-codes for the commands and command attributes are hardwired into the controller. Because the association is hardwired into the controller, this pre-set association cannot be changed after the controller is manufactured. Accordingly, if new commands are defined in standards that are implemented after tape out of the controller, the op-codes for those new commands will not be known to the controller. Therefore, those new commands will need to be executed exclusively by firmware instead of by the faster hardware logic, which can result in a loss of performance.
Overview
Embodiments of the present invention are defined by the claims, and nothing in this section should be taken as a limitation on those claims.
By way of introduction, the below embodiments relate to a storage module and method for configuring command attributes. In one embodiment, a storage module is provided comprising a controller having hardware function blocks and further comprising a memory storing associations between command codes and command attributes for the hardware function blocks. The storage module receives a command that includes a command code and determines if the command code is stored in the memory. If the command code is stored in the memory, the storage module configures the hardware function blocks using the command attributes associated with command code and processes the command with the configured hardware function blocks. The associations are configurable after the storage module has been manufactured. This allows new or different associations to be defined after the storage module has been manufactured.
Other embodiments are possible, and each of the embodiments can be used alone or together in combination. Accordingly, various embodiments will now be described with reference to the attached drawings.